﻿using System.Collections.Generic;

namespace DBCook.Models
{
    public class CompareDBResult
    {
        #region 定义类 枚举
        public enum EnumResultType
        {
            Add,
            Delete,
            Update
        }

        public class BaseResult
        {
            public EnumResultType Type { get; set; }
            public string Description { get; set; }
        }

        public class ParameterResult : BaseResult
        {
            public string Name { get; set; }
            public object Value1 { get; set; }
            public object Value2 { get; set; }
        }

        public class TableResult : BaseResult
        {
            public string Name { get; set; }
            public List<ParameterResult> Parameters { get; set; }
            public List<ColumnResult> Columns { get; set; }
            public List<IndexResult> Indexes { get; set; }
        }

        public class ColumnResult : BaseResult
        {
            public string Name { get; set; }
            public List<ParameterResult> Parameters { get; set; }
        }

        public class IndexResult : BaseResult
        {
            public string ColumnNames { get; set; }
            public List<ParameterResult> Parameters { get; set; }
        }

        #endregion
        public List<ParameterResult> Parameters { get; set; }

        public List<TableResult> Tables { get; set; }
    }
}
